<#include "/admin/inc/ctx.html">
<#include "/admin/inc/pagerForm.html">
<div class="pageHeader">
	<form rel="pagerForm" onsubmit="return navTabSearch(this);" action="${ctx}/admin/role/list">
	<div class="searchBar">
		<ul class="searchContent">
			<li>
				<label>角色名称：</label>
				<input type="text" name="keywords"/>
			</li>
		</ul>
		<div class="subBar">
			<ul>
				<li><div class="buttonActive"><div class="buttonContent"><button type="submit">查询</button></div></div></li>
			</ul>
		</div>
	</div>
	</form>
</div>

<div class="pageContent">
	<div class="panelBar">
		<ul class="toolBar">
		    <@shiro.hasPermission name="admin:role:form">
			<li><a  href="${ctx}/admin/role/form" target="dialog"  width="400" height="220"><i class="fa fa-plus"></i>添加</a></a></li>
			<li><a  href="${ctx }/admin/role/form?id={id}" target="dialog" warn="请选择一条记录"><i class="fa fa-edit"></i>修改</a></a></li>
			</@shiro.hasPermission>
			<@shiro.hasPermission name="admin:role:delete">
			<li><a  href="${ctx}/admin/role/delete?id={id}" target="ajaxTodo" title="确定要删除吗？" warn="请选择一条记录"><i class="fa fa-trash-o">&nbsp;</i>删除</a></a></li>
			</@shiro.hasPermission>
			<li class="line">line</li>
		</ul>
	</div>

	<div layoutH="124">
	<table class="list"  targetType="navTab">
		<thead>
		  <tr>
	        <th width="3%"><input type="checkbox" group="ids" class="checkboxCtrl"></th>
	        <th width="5%">编号</th>
	        <th width="10%">角色名称</th>
	        <th width="10%">备注</th>
	        <th width="10%">创建时间</th>
            <th width="10%">操作</th>	      
            </tr>
		</thead>
		<tbody>
		<#list pageData.page.records as bean>
	        <tr align="center" target="id" rel="${bean.id }">
	        <td><input  type="checkbox" name="ids" value="${bean.id }" /></td>
	         <td>${bean.id }</td>
	         <td>${bean.name }</td>
	         <td>${(bean.remark)! }</td>
	         <td>${(bean.createTime)! }</td>
	         <td align="center">
	            <@shiro.hasPermission name="admin:role:delete">
				<a title="删除" target="ajaxTodo"  callback="ajaxTodoDone" href="${ctx}/admin/role/delete?id=${bean.id }"  class="delButton"><i class="fa fa-remove"></i>&nbsp;删除</a>
				</@shiro.hasPermission>
				<@shiro.hasPermission name="admin:role:form">
				<a title="编辑" target="dialog" width="400" height="220" href="${ctx }/admin/role/form?id=${bean.id}" class="editButton"><i class="fa fa-file-text-o"></i>&nbsp;编辑</a>
				</@shiro.hasPermission>
				<@shiro.hasPermission name="admin:role:authorizeForm">
				<a title="设置权限" target="dialog" width="250" height="400" href="${ctx }/admin/role/authorizeForm?id=${bean.id}" class="addButton">设置权限</a>
				</@shiro.hasPermission>
			</td>
	      </tr>
        </#list>
		</tbody>
	</table>
	</div>
	<#include "/admin/inc/pagination.html">
</div>
